<!--
 * @Description: 
 * @Author: charles
 * @Date: 2021-12-20 16:47:29
 * @LastEditors: HeAo
 * @LastEditTime: 2022-01-06 19:00:27
-->
<template>
  <div class="workorder">
    <van-nav-bar
      title="工单详情"
      left-text="返回"
      left-arrow
      @click-left="$router.go(-1)"
    />

    <van-cell-group>
      <van-field v-model="order.type" label="工单类型" readonly />
      <van-field v-model="order.status" label="工单状态" readonly />
      <van-field v-model="order.engineer_name" label="工程名称" readonly />
      <van-field v-model="order.device_name" label="设备名称" readonly />
      <van-field v-model="order.bill_why" label="申报原因" readonly />
      <van-field
        name="image"
        label="申报图片"
        :value="order.begin_photos.length == 0 ? '暂无数据' : ''"
        readonly
      />
      <div>
        <img
          v-for="(item, index) in order.begin_photos"
          :key="index"
          width="150px"
          :src="item"
          alt="暂无图片"
        />
      </div>
      <van-field
        name="image"
        label="处理图片"
        :value="order.end_photos.length == 0 ? '暂无数据' : ''"
        readonly
      />
      <div>
        <img
          v-for="(item, index) in order.end_photos"
          :key="index"
          width="150px"
          :src="item"
          alt="暂无图片"
        />
      </div>
    </van-cell-group>
  </div>
</template>
<script>
import { get } from "../../utils/request";
import axios from "axios";
import { Toast } from "vant";

export default {
  data() {
    return {
      order: {},
      imgList: [],
    };
  },
  methods: {},
  mounted() {
    this.order = this.$route.query;
  },
};
</script>
<style scoped>
.workorder {
  font-size: 12px;
  color: #666;
  padding-bottom: 50px;
  background-color: #f4f4f4;
}
</style>
<style >
.van-uploader__wrapper {
  width: 100%;
}

.van-uploader__wrapper > div {
  flex: 1;
}

.van-uploader__wrapper > div .van-uploader__preview-image {
  width: 100%;
}
</style>